import 'package:C20Driver/routers/navigator_util.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/screenutil.dart';

class CertificatesInfo extends StatefulWidget {
  @override
  _CertificatesInfoState createState() => _CertificatesInfoState();
}

class _CertificatesInfoState extends State<CertificatesInfo> {
  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('证件信息'),
        elevation: 0,
      ),
      body: Container(
        padding: EdgeInsets.fromLTRB(
            ScreenUtil().setWidth(32),
            ScreenUtil().setWidth(44),
            ScreenUtil().setWidth(32),
            ScreenUtil().setWidth(0)),
        width: double.infinity,
        height: double.infinity,
        color: Color(0xffEFF3F9),
        child: Column(
          children: [
            Row(
              children: [
                Icon(
                  Icons.error_outline,
                  color: Color(0xff3FB956),
                  size: ScreenUtil().setWidth(40),
                ),
                Text(
                  '证件信息每半年可更新1次，如有问题可致电客服',
                  style: TextStyle(
                      color: Color(0xff3FB956),
                      fontSize: ScreenUtil().setWidth(28),
                      fontWeight: FontWeight.w400),
                ),
              ],
            ),
            SizedBox(
              height: ScreenUtil().setWidth(44),
            ),
            Container(
              width: ScreenUtil().setWidth(696),
              padding: EdgeInsets.all(ScreenUtil().setWidth(32)),
              decoration: BoxDecoration(
                color: Color(0xffffffff),
                borderRadius: BorderRadius.all(
                  Radius.circular(
                    ScreenUtil().setWidth(32),
                  ),
                ),
              ),
              child: Row(
                mainAxisAlignment: MainAxisAlignment.spaceBetween,
                children: [
                  Column(
                    crossAxisAlignment: CrossAxisAlignment.start,
                    children: [
                      Text(
                        '身份证/驾驶证',
                        style: TextStyle(
                            color: Color(0xff333333),
                            fontSize: ScreenUtil().setWidth(30),
                            fontWeight: FontWeight.w500),
                      ),
                      SizedBox(
                        height: ScreenUtil().setWidth(15),
                      ),
                      Text(
                        '请提前准备身份证原件',
                        style: TextStyle(
                            color: Color(0xff999999),
                            fontSize: ScreenUtil().setWidth(28),
                            fontWeight: FontWeight.w400),
                      ),
                    ],
                  ),
                  InkWell(
                    onTap: () {
                      NavigatorUtil.jump(context, '/uploadIdCard');
                    },
                    child: Container(
                      alignment: Alignment.center,
                      width: ScreenUtil().setWidth(176),
                      height: ScreenUtil().setWidth(62),
                      decoration: BoxDecoration(
                        color: Colors.transparent,
                        border: Border.all(
                          width: ScreenUtil().setWidth(1),
                          color: Color(0xff3FB956),
                        ),
                        borderRadius: BorderRadius.all(
                          Radius.circular(
                            ScreenUtil().setWidth(31),
                          ),
                        ),
                      ),
                      child: Text(
                        '更新证件',
                        style: TextStyle(
                            color: Color(0xff3FB956),
                            fontSize: ScreenUtil().setWidth(26),
                            fontWeight: FontWeight.w400),
                      ),
                    ),
                  )
                ],
              ),
            ),
            SizedBox(
              height: ScreenUtil().setWidth(32),
            ),
            Container(
              width: ScreenUtil().setWidth(696),
              padding: EdgeInsets.all(ScreenUtil().setWidth(32)),
              decoration: BoxDecoration(
                color: Color(0xffffffff),
                borderRadius: BorderRadius.all(
                  Radius.circular(
                    ScreenUtil().setWidth(32),
                  ),
                ),
              ),
              child: Row(
                mainAxisAlignment: MainAxisAlignment.spaceBetween,
                children: [
                  Column(
                    crossAxisAlignment: CrossAxisAlignment.start,
                    children: [
                      Text(
                        '行驶证',
                        style: TextStyle(
                            color: Color(0xff333333),
                            fontSize: ScreenUtil().setWidth(30),
                            fontWeight: FontWeight.w500),
                      ),
                      SizedBox(
                        height: ScreenUtil().setWidth(15),
                      ),
                      Text(
                        '请提前准备行驶证原件',
                        style: TextStyle(
                            color: Color(0xff999999),
                            fontSize: ScreenUtil().setWidth(28),
                            fontWeight: FontWeight.w400),
                      ),
                    ],
                  ),
                  InkWell(
                    onTap: () {
                      NavigatorUtil.jump(context, '/drivingLicenseVehicle');
                    },
                    child: Container(
                      alignment: Alignment.center,
                      width: ScreenUtil().setWidth(176),
                      height: ScreenUtil().setWidth(62),
                      decoration: BoxDecoration(
                        color: Colors.transparent,
                        border: Border.all(
                          width: ScreenUtil().setWidth(1),
                          color: Color(0xff3FB956),
                        ),
                        borderRadius: BorderRadius.all(
                          Radius.circular(
                            ScreenUtil().setWidth(31),
                          ),
                        ),
                      ),
                      child: Text(
                        '更新证件',
                        style: TextStyle(
                            color: Color(0xff3FB956),
                            fontSize: ScreenUtil().setWidth(26),
                            fontWeight: FontWeight.w400),
                      ),
                    ),
                  )
                ],
              ),
            )
          ],
        ),
      ),
    );
  }
}
